<!DOCTYPE html>
<html lang="CN-ch">
    <head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
    <title>举重</title>
    <script>
        function hide(){
            document.getElementById('mytc').style.display = 'none';
        }
		var a = 1;
        function action(){
			if(a === 1){a = 2;}
			else{a = 1;}
            document.getElementById("human").src = './image/shidun' + a + '.png';
        }
      </script>
    <style>
        html,body{
            width: 100%;
            height: 100%;
            margin: 0;
            padding: 0;
        }
        .container{
            max-width: 99%;
            position: relative;
            margin: 0 auto;
            text-align: center;
            height: 100vh;
            overflow: hidden;
        }
        .bg{
            position: relative;
            margin: auto;
            width: fit-content;
            overflow: hidden;
        }
        .bgimg{
            max-width: 100%;
            max-height: 100%;
            height: 100vh;
        }

        .tc{
            position: absolute;
            background-image: url("./image/tanchuang2.png");
            background-size: cover;
            top: 30%;
            left: 10%;
            display: flex;
            border-radius: 10px;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            background-color: #fff;
            z-index: 1;
            animation: zoomIn 0.5s forwards;
            background-repeat: no-repeat;
            width: 80%;
            height: 30%;
        }

        @keyframes zoomIn {
            from {
              transform: scale(0.5);
            }
            to {
              transform: scale(1);
            }
          }
        #hideButton{
			position: absolute;
			top: 0;
			left: 38%;
			width: 33%;
			height: 20%;
			background-color: transparent; /* 设置按钮背景为透明 */
			border: none; /* 去掉按钮边框 */
			cursor: pointer; /* 鼠标悬停时显示指针 */

        }
    </style>
</head>
<body>
    <div class="container">
        <div class="bg">
            <button id="hideButton"  onclick="action()"></button>       
            <img class="bgimg" src="./image/shidun1.png" id="human">

            <div class="tc" id="mytc">
                <p>选择举重物，点击人物，开始运动</p>
                <button onclick="hide()">OK</button>
            </div>

        </div>
        
    </div>

</body>
</html>